<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core"  %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<base  href="<%=basePath %>"/>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<script type="text/javascript" src="js/jquery-1.3.2.js"></script>
<script type="text/javascript" src="js/captify.tiny.js"></script>
<script type="text/javascript" src="js/jcarousellite_1.0.1.min.js"></script>
<script type="text/javascript" src="js/evan.js"></script>
<script type="text/javascript" src="js/index.js"></script>
<script type="text/javascript" src="js/roll.js" charset="gbk"></script>
	<script type="text/javascript">
	
	$(function(){
		$('.content_mid_show img').captify({});
	});
	$(function(){
		$('.carousel img').captify({});
	});
	
	</script>

<link href="css/captify.css" rel="stylesheet" type="text/css" />
<link href="css/index_category.css" rel="stylesheet" type="text/css" />
<link href="css/index.css" rel="stylesheet" type="text/css" />
<title>首页</title>
</head>

<body>
	<div id="container">
	
	
		<div id="navi_container">
		
			<!--这里是navigation的顶部栏-->
			<div id="navi_top">
				<div class="navi_left">${cityName}站</div>
				<div class="city">
				</div>
				<div class="navi_left">网页版</div>
				
				<div class="navi_right">推广使用</div>
				
			<c:choose>
               <c:when test="${sessionScope.nickName==null}">
               <div class="navi_right"><a href="#">注册</a></div>
               <div class="navi_right"><a href="user/login_queryLoginPage.action">登录</a></div>
               </c:when>                 
          	  <c:otherwise>
          	  
          	  <div class="navi_right"><a  href="user/PersonSpace_queryMsgStore.action">我的收藏</a></div>
          	  <div class="navi_right"><a href="user/login_doLogout.action">注销</a></div>
          	  <div class="navi_right"><a target="right" href="user/PersonSpace_queryLabelMsg.action">欢迎${sessionScope.nickName}</a></div>
          	 </c:otherwise>
        	</c:choose>
				
				
				
			</div>
			<!--这里是navigation的顶部栏-->
			
			<!--这里是navigation的infor栏-->
			<div id="navigation_infor">
				<div id="logo"><a href="index.action"><img src="img/logo.png" width="220" height="77" border="0"/></a></div>
				<div id="search_content">
						<form action="user/search_doSearch.action?pagebean.currentPage=1" method="post" name="search" id="search" >
							<input type="text" size="37" name="keyword" />
							<input type="submit" value="搜索" id="commomSearch" />
							<!-- <input type="submit" value="高级搜索" id="advanceSearch" /> -->
						</form>
					</div>
			</div>
			<!--这里是navigation的infor栏-->
			
			<!--这里是navigation导航栏-->
			<div id="navigation">
				<div class="navigator_space_left"></div>
				<a href="index.action"><div id="nvg0" class="navigator">首页</div></a>
				<c:forEach  var="catagory"  items="${list}"   varStatus="s">
			      <a href="user/publish_queryCataSecondList.action?catagoryId=${catagory.catagoryID}"><div id="nvg${s.index+1}" class="navigator">${catagory.catagoryName}</div></a>     
				</c:forEach>
			</div>
			<!--这里是navigation导航栏-->
		
		</div>
		
		
		
		<div id="content_container">
		
		
			<!--下面这段主要是进行扩展  -->
			<div class="my_left_category">
					<div class="my_left_category">
						<div class="my_left_cat_list">
						   <c:forEach  var="catagory"  items="${list}">
						      <!-- 下面是列表的一段 -->
						           <h2><a href="user/publish_queryCataSecondList.action?catagoryId=${catagory.catagoryID}">${catagory.catagoryName}</a></h2>  
						    <div class="h2_cat" onmouseover="this.className='h2_cat active_cat'" onmouseout="this.className='h2_cat'">
								<h3>
								<c:forEach  var="small1"  items="${catagory.list}"  begin="1"  end="3" step="1">
								    <a href="user/publish_querySecondList.action?smallId=${small1.smallID}&catagoryId=${catagory.catagoryID}">${small1.smallName}  </a>
								</c:forEach>
								</h3>
										<div class="h3_cat">
											<div class="shadow">
												<div class="shadow_border">
													<ul>
													  <c:forEach  var="small"  items="${catagory.list}">
													      <li><a href="user/publish_querySecondList.action?smallId=${small.smallID}&catagoryId=${catagory.catagoryID}">${small.smallName}</a></li>
													  </c:forEach>
													</ul>
												</div>
											</div>
										</div>
							</div>
						   </c:forEach>
						</div>
					</div>
					</div>
				<!--上面这段主要是进行扩展  -->	
				
				<!--这里开始是poster-->
				<div id="content_mid_poster">
					<script>
					var widths=465;
					var heights=305;
					var counts=6;
					img1=new Image ();img1.src='img/book1.jpg';
					img2=new Image ();img2.src='img/book2.jpg';
					img3=new Image ();img3.src='img/cloth.jpg';
					img4=new Image ();img4.src='img/cloth2.jpg';
					img5=new Image ();img5.src='img/digital.jpg';
					img6=new Image ();img6.src='img/yueqi.jpg';
					url1=new Image ();url1.src='user/publish_queryCataSecondList.action?catagoryId=1';//书
					url2=new Image ();url2.src='user/publish_queryCataSecondList.action?catagoryId=1';//书
					url3=new Image ();url3.src='user/publish_queryCataSecondList.action?catagoryId=3';//衣服
					url4=new Image ();url4.src='user/publish_queryCataSecondList.action?catagoryId=3';//衣服
					url5=new Image ();url5.src='user/publish_queryCataSecondList.action?catagoryId=2';//数码产品
					url6=new Image ();url6.src='user/publish_queryCataSecondList.action?catagoryId=6';//乐器
					var nn=1;
					var key=0;
					function change_img()
					{if(key==0){key=1;}
					else if(document.all)
					{document.getElementById("pic").filters[0].Apply();document.getElementById("pic").filters[0].Play(duration=2);}
					eval('document.getElementById("pic").src=img'+nn+'.src');
					eval('document.getElementById("url").href=url'+nn+'.src');
					for (var i=1;i<=counts;i++){document.getElementById("xxjdjj"+i).className='axx';}
					document.getElementById("xxjdjj"+nn).className='bxx';
					nn++;if(nn>counts){nn=1;}
					tt=setTimeout('change_img()',4000);}
					function changeimg(n){nn=n;window.clearInterval(tt);change_img();}
					document.write('<style>');
					document.write('.axx{padding:1px 7px;border-left:#cccccc 1px solid;}');
					document.write('a.axx:link,a.axx:visited{text-decoration:none;color:#fff;line-height:12px;font:9px sans-serif;background-color:#666;}');
					document.write('a.axx:active,a.axx:hover{text-decoration:none;color:#fff;line-height:12px;font:9px sans-serif;background-color:#999;}');
					document.write('.bxx{padding:1px 7px;border-left:#cccccc 1px solid;}');
					document.write('a.bxx:link,a.bxx:visited{text-decoration:none;color:#fff;line-height:12px;font:9px sans-serif;background-color:#D34600;}');
					document.write('a.bxx:active,a.bxx:hover{text-decoration:none;color:#fff;line-height:12px;font:9px sans-serif;background-color:#D34600;}');
					document.write('</style>');
					document.write('<div style="width:'+widths+'px;height:'+heights+'px;overflow:hidden;text-overflow:clip;">');
					document.write('<div><a id="url"><img id="pic" style="border:0px;filter:progid:dximagetransform.microsoft.wipe(gradientsize=1.0,wipestyle=4, motion=forward)" width='+widths+' height='+heights+' /></a></div>');
					document.write('<div style="filter:alpha(style=1,opacity=10,finishOpacity=80);background: #888888;width:100%-2px;text-align:right;top:-12px;position:relative;margin:1px;height:12px;padding:0px;margin:0px;border:0px;">');
					for(var i=1;i<counts+1;i++){document.write('<a href="javascript:changeimg('+i+');" id="xxjdjj'+i+'" class="axx" target="_self">'+i+'</a>');}
					document.write('</div></div>');
					change_img();
				</script>
				</div>
				<!--这里开始是poster-->
				
				<!--这里开始是右边的图片-->
						<div id="content_top_right">
						<div id="content_top_right_pic">
							<img src="img/1_r1_c1.png" align="right" height="260" />
						</div>
						
						
						<!-- 注意，下面这段是后台要写入的数据，里面的数据只是暂时存放用于测试 -->
						<div id="hideMessage" style="display:none">
						<c:forEach  var="topic"  items="${topics}">
						   ${topic.title}/
						</c:forEach>
						<!-- 张三发布了物品1/李四发布了物品2/王五发布了物品3/张三发布了物品2/李四发布了物品3/王五发布了物品4/Evan发布了 -->
						</div>
						<!-- 注意，上面这段是后台要写入的数据，里面的数据只是暂时存放用于测试 -->
						<div id="message">
							<marquee direction="up" id="margq" height="25" scrolldelay="200" loop="-1">
								<div style="text-align:center">求购吧新帖发布栏</div>
							</marquee> 
						</div>
					</div>
				<!--这里开始是右边的图片-->
				

				<!--中间端特别特别注意样式，绝对不用轻易去改动任何的class和id，还有类名和属性值  by 郭Evan -->
				<!--中间中断开始-->
				
				           <!-- 第一组大类数据 -->				
				           <div class="content_mid_show">
				             <c:forEach  var="entry"    items="${map}"   begin="0"  end="0"  step="1">
				                   <c:forEach  var="msg"   items="${entry.value.list}"  begin="1"  end="1"   step="1">
				                        <div class="content_mid_category">${msg.catagoryName }</div>  <!-- 输出一次 -->      
				                   </c:forEach>
				             </c:forEach>
				           
									<div class="jCarouselLite_first">
									<div class="prev_first" style="width:16px;height:auto;position:absolute; float:left; margin-top:50px; margin-left:0px; padding-left:0px; cursor:pointer"><img src="img/left.png" /></div>
									<ul style="list-style:none">

                               <c:forEach  var="entry"    items="${map}"   begin="0"  end="0"  step="1">
                                   <c:forEach  var="msg"  items="${entry.value.list}"   begin="1"    step="1">
                                   <!-- 取得当前记录的属性值 -->
                                       <c:forEach  var="attribute"   items="${msg.attributes}"  begin="1"  end="2"  step="1"   varStatus="s">
                                            <c:if test="${s.index==1}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var1"></c:set> 
                                            </c:if>
                                            
                                            <c:if test="${s.index==2}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}" var="var2"></c:set> 
                                            </c:if>
                                               
                                       </c:forEach>        
                                   
                                        <!-- 当前数据 -->
								         <li style="border:1px solid #fff">
								  			<a href="user/publish_queryPubMsg.action?pubMsg.publishID=${msg.publishID}" style="display:block">
											<img src="${msg.cover}" width="210" height="170" alt="${var1 }" title="${var2 }" border="0"/>	
								 			 </a>						
							   			 </li>     
                                   </c:forEach>
                               </c:forEach>
									</ul>
									<div class="next_first" style="height:50px; width:16px; position:absolute; cursor:pointer; margin-left:978px; margin-top:50px"><img src="img/right.png" /></div>
								</div>
							</div>
		     	 
		     	     
		     	     
		     	     <!-- 第二组大类数据 -->				
				           <div class="content_mid_show">
				             <c:forEach  var="entry"    items="${map}"   begin="1"  end="1"  step="1">
				                   <c:forEach  var="msg"   items="${entry.value.list}"  begin="1"  end="1"   step="1">
				                        <div class="content_mid_category">${msg.catagoryName }</div>  <!-- 输出一次 -->      
				                   </c:forEach>
				             </c:forEach>
				           
									<div class="jCarouselLite_second">
									<div class="prev_second" style="width:16px;height:auto;position:absolute; float:left; margin-top:50px; margin-left:0px; padding-left:0px; cursor:pointer"><img src="img/left.png" /></div>
									<ul style="list-style:none">

                               <c:forEach  var="entry"    items="${map}"   begin="1"  end="1"  step="1">
                                   <c:forEach  var="msg"  items="${entry.value.list}"   begin="1"   step="1">
                                   <!-- 取得当前记录的属性值 -->
                                       <c:forEach  var="attribute"   items="${msg.attributes}"  begin="1"  end="2"  step="1"   varStatus="s">
                                            <c:if test="${s.index==1}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var1"></c:set> 
                                            </c:if>
                                            
                                            <c:if test="${s.index==2}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var2"></c:set> 
                                            </c:if>
                                               
                                       </c:forEach>        
                                   
                                        <!-- 当前数据 -->
								         <li style="border:1px solid #fff">
								  			<a href="user/publish_queryPubMsg.action?pubMsg.publishID=${msg.publishID}" style="display:block">
											<img src="${msg.cover}" width="210" height="170" alt="${var1 }" title="${var2 }" border="0"/>	
								 			 </a>						
							   			 </li>     
                                   </c:forEach>
                               </c:forEach>
									</ul>
									<div class="next_second" style="height:50px; width:16px; position:absolute; cursor:pointer; margin-left:978px; margin-top:50px"><img src="img/right.png" /></div>
								</div>
							</div>

		     	 		     	 
				      <!-- 第三组大类数据 -->				
				           <div class="content_mid_show">
				             <c:forEach  var="entry"    items="${map}"   begin="2"  end="2"  step="1">
				                   <c:forEach  var="msg"   items="${entry.value.list}"  begin="1"  end="1"   step="1">
				                        <div class="content_mid_category">${msg.catagoryName }</div>  <!-- 输出一次 -->      
				                   </c:forEach>
				             </c:forEach>
				           
									<div class="jCarouselLite_third">
									<div class="prev_third" style="width:16px;height:auto;position:absolute; float:left; margin-top:50px; margin-left:0px; padding-left:0px; cursor:pointer"><img src="img/left.png" /></div>
									<ul style="list-style:none">

                               <c:forEach  var="entry"    items="${map}"   begin="2"  end="2"  step="1">
                                   <c:forEach  var="msg"  items="${entry.value.list}"   begin="1"   step="1">
                                   <!-- 取得当前记录的属性值 -->
                                       <c:forEach  var="attribute"   items="${msg.attributes}"  begin="1"  end="2"  step="1"   varStatus="s">
                                            <c:if test="${s.index==1}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var1"></c:set> 
                                            </c:if>
                                            
                                            <c:if test="${s.index==2}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var2"></c:set> 
                                            </c:if>
                                               
                                       </c:forEach>        
                                   
                                        <!-- 当前数据 -->
								         <li style="border:1px solid #fff">
								  			<a href="user/publish_queryPubMsg.action?pubMsg.publishID=${msg.publishID}" style="display:block">
											<img src="${msg.cover}" width="210" height="170" alt="${var1 }" title="${var2 }" border="0"/>	
								 			 </a>						
							   			 </li>     
                                   </c:forEach>
                               </c:forEach>
									</ul>
									<div class="next_third" style="height:50px; width:16px; position:absolute; cursor:pointer; margin-left:978px; margin-top:50px"><img src="img/right.png" /></div>
								</div>
							</div>
							
							
							<!-- 第四组大类数据 -->				
				           <div class="content_mid_show">
				             <c:forEach  var="entry"    items="${map}"   begin="3"   step="1">
				                   <c:forEach  var="msg"   items="${entry.value.list}"  begin="1"  end="1"   step="1">
				                        <div class="content_mid_category">${msg.catagoryName }</div>  <!-- 输出一次 -->      
				                   </c:forEach>
				             </c:forEach>
				           
									<div class="jCarouselLite_fouth">
									<div class="prev_fouth" style="width:16px;height:auto;position:absolute; float:left; margin-top:50px; margin-left:0px; padding-left:0px; cursor:pointer"><img src="img/left.png" /></div>
									<ul style="list-style:none">

                               <c:forEach  var="entry"    items="${map}"   begin="3"  end="3"  step="1">
                                   <c:forEach  var="msg"  items="${entry.value.list}"   begin="1"   step="1">
                                   <!-- 取得当前记录的属性值 -->
                                       <c:forEach  var="attribute"   items="${msg.attributes}"  begin="1"  end="2"  step="1"   varStatus="s">
                                            <c:if test="${s.index==1}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var1"></c:set> 
                                            </c:if>
                                            
                                            <c:if test="${s.index==2}">
                                                 <c:set  scope="page"   value="${attribute.attributeName}:${attribute.attributeValue}"  var="var2"></c:set> 
                                            </c:if>
                                               
                                       </c:forEach>        
                                   
                                        <!-- 当前数据 -->
								         <li style="border:1px solid #fff">
								  			<a href="user/publish_queryPubMsg.action?pubMsg.publishID=${msg.publishID}" style="display:block">
											<img src="${msg.cover}" width="210" height="170" alt="${var1 }" title="${var2 }" border="0"/>	
								 			 </a>						
							   			 </li>     
                                   </c:forEach>
                               </c:forEach>
									</ul>
									<div class="next_fouth" style="height:50px; width:16px; position:absolute; cursor:pointer; margin-left:978px; margin-top:50px"><img src="img/right.png" /></div>
								</div>
							</div>
				<!--中间中断开始-->
				<!--中间端特别特别注意样式，绝对不用轻易去改动任何的class和id，还有类名和属性值  by 郭Evan -->
				
				
				<!--底部开始-->
				<div id="bottom">
					<div style="height:30px; font-weight:bold; font-size:18px; text-indent:30px;">全部类目</div>
					
					<c:forEach  var="catagory"  items="${list}">
					    <div class="bottom_category">
							<strong style="font-weight:bold; font-size:14px">${catagory.catagoryName}</strong>
							<c:forEach  var="small"  items="${catagory.list }">
							   <a href="user/publish_querySecondList.action?smallId=${small.smallID}&catagoryId=${catagory.catagoryID}">${small.smallName}</a>
							</c:forEach>
					   </div>
					</c:forEach>
					
				</div>
				<!--底部开始-->
		</div>
		
			<div style="border-bottom:1px solid #CCCCCC"></div>
			<table align="center" width="1002" style="margin:0 auto;font-family:'新宋体';font-size:12px;margin-bottom:20px;margin-top:15px">
				<tr height="10px">
					<td height="20" align="left" style="text-indent:15px;">ICP证粤B2-20090191</td>
					<td height="20" align="left" style="text-indent:15px;">国际联网备案</td>
					<td height="20" align="left" style="text-indent:15px;">北京网络行业协会</td>
					<td height="20" align="left" style="text-indent:15px;">京公网安备110000000013号</td>
				</tr>
				<tr height="10px">
					<td height="20" align="left" style="text-indent:15px;">增值电信业务经营许可证B2-20090058</td>
					<td height="20" align="left" style="text-indent:15px;">违法不良信息举报中心</td>
					<td height="20" align="left" style="text-indent:15px;">网易网站相关资质证明</td>
					<td height="20" align="left" style="text-indent:15px;">举报邮箱：1341212325@qq.com</td>
				</tr>
				<tr height="10px">
					<td height="20" align="left" style="text-indent:15px;">江西师范大学</td>
					<td height="20" align="left" style="text-indent:15px;">江西南昌大学</td>
					<td height="20" align="left" style="text-indent:15px;">江西省文明宣传委员会</td>
					<td height="20" align="left" style="text-indent:15px;">文明办网文明上网举报电话：010-82558163</td>
				</tr>
			</table>
			
			<div id="navigation_bottom">
				<div class="navigator_bottom_space_left"></div>
				<a href="#"><div id="nvg1" class="navigator_bottom">&copy;&nbsp;&nbsp;2013-2014&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg2" class="navigator_bottom"  style="width:120px">江西师大&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg3" class="navigator_bottom" style="padding-left:0px;">简介&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg4"class="navigator_bottom">联系方法&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg5" class="navigator_bottom">招聘信息&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg6" class="navigator_bottom">关于我们&nbsp;&nbsp;|</div></a>
				<a href="#"><div id="nvg7" class="navigator_bottom">建议反馈</div></a>
			</div>

			<div style="height:30px; width:1002px; margin:0 auto"></div>
	</div>
</body>
</html>

